]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
boxpointer: Don't hide when we're already hidden
authorJasper St. Pierre <jstpierre@mecheye.net>
Wed, 20 Nov 2013 03:39:39 +0000 (22:39 -0500)
committerJasper St. Pierre <jstpierre@mecheye.net>
Wed, 20 Nov 2013 04:23:25 +0000 (23:23 -0500)
You would think we would already do something like this, but apparently
lots of code was calling hide() without checking if the box pointer was
already visible, causing it to queue a full tween. The biggest win was
with ibusCandidatePopup.js, which called hide() on every DBus message.

This increases the performance for me to enter the overview by a tiny
bit. The remaining time is spent updating the frequent apps / all apps
display.

https://bugzilla.gnome.org/show_bug.cgi?id=712727

js/ui/boxpointer.js

index c8a15d3f9251d61f79f458de6db94e22ce341ff8..e94033710e272ca4be441302be0589b39e7dca13 100644 (file)
@@ -121,6 +121,9 @@ const BoxPointer = new Lang.Class({
     },
 
     hide: function(animate, onComplete) {
+        if (!this.actor.visible)
+            return;
+
         let xOffset = 0;
         let yOffset = 0;
         let themeNode = this.actor.get_theme_node();